package com.sk.gzwater.view;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import org.ksoap2.SoapEnvelope;
import org.ksoap2.serialization.SoapObject;
import org.ksoap2.serialization.SoapSerializationEnvelope;
import org.ksoap2.transport.HttpTransportSE;

import com.sk.gzewop.R;
import com.sk.gzwater.adapter.ShujutianbaoWeiwanchengRenwuDatalistAdapter;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.widget.ListView;
import android.widget.TextView;

public class ShujuTianbaoWeiwanchengRenwuDatalist extends Activity {
	private ArrayList<HashMap<String, String>> dataList;
	private ListView dataListView;
	private Intent intent;
	private TextView name,time;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.shujutianbaoweiwanchengrenwu_datalist);
		intent = getIntent();
		initialize();
	}
		
	
	private void initialize() {	
		dataList = (ArrayList<HashMap<String,String>>)intent.getSerializableExtra("datalist");
		dataListView = (ListView) findViewById(R.id.shujutianbaoweiwanchengrenwu_datalist);
		ShujutianbaoWeiwanchengRenwuDatalistAdapter listadapter = new ShujutianbaoWeiwanchengRenwuDatalistAdapter(ShujuTianbaoWeiwanchengRenwuDatalist.this, dataList);
		dataListView.setAdapter(listadapter);
		
		name = (TextView)findViewById(R.id.tv_shujutianbaoweiwanchengrenwu_datalist_name);
		time = (TextView)findViewById(R.id.tv_shujutianbaoweiwanchengrenwu_datalist_time);
		
		name.setText(intent.getExtras().getString("name"));
		time.setText(intent.getExtras().getString("starttime")+"~"+intent.getExtras().getString("endtime"));

	}
}
